package com.urbanski.clipboard.common.message;

public class JoinResponse implements Response
{
	private static final long serialVersionUID = 1L;
	
	public static enum JoinResponseValue
	{
		SUCCESS("Successfully joined session"), INVALID_PASSWORD("Invalid session password"), SESSION_DOES_NOT_EXIST("Session does not exist"), ALREADY_MEMBER("Already a member of the session");
		
		private String errorMessage;
		
		private JoinResponseValue(String errorMessage)
		{
			this.errorMessage = errorMessage;
		}
		
		public String getErrorMessage()
		{
			return errorMessage;
		}
	}
	
	private JoinResponseValue response;
	
	public JoinResponse(JoinResponseValue response)
	{
		this.response = response;
	}
	
	public JoinResponseValue getResponse()
	{
		return response;
	}
	

	
	public String getResponseText()
	{
		return response.getErrorMessage();
	}

}
